bpo-36384: Leading zeros in IPv4 addresses are no longer tolerated (GH-25099) (GH...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sun, 2 May 2021 13:49:03 +0000 (06:49 -0700)
committerArnaud Rebillout <arnaudr@debian.org>
Tue, 14 Apr 2026 04:38:32 +0000 (11:38 +0700)
commit9fbab009c83ebb02f8ddb185b4ac0dff55015403
treefae5817045e157f0f33a8ed59b9716a8ca4e5418
parentfa3a088bba15ab9dc85a82e0edf97d6b79fa9b83
bpo-36384: Leading zeros in IPv4 addresses are no longer tolerated (GH-25099) (GH-25815)

Reverts commit e653d4d8e820a7a004ad399530af0135b45db27a and makes
parsing even more strict. Like socket.inet_pton() any leading zero
is now treated as invalid input.

Signed-off-by: Christian Heimes <christian@python.org>
Co-authored-by: Ɓukasz Langa <lukasz@langa.pl>
(cherry picked from commit 60ce8f0be6354ad565393ab449d8de5d713f35bc)

Gbp-Pq: Name 0009-bpo-36384-Leading-zeros-in-IPv4-addresses-are-no-lon.patch
Doc/library/ipaddress.rst
Doc/tools/susp-ignored.csv
Lib/ipaddress.py
Lib/test/test_ipaddress.py